//
//  BandItemCell.m
//  SSWiFi
//
//  Created by 酷安 @啥也不会啊啊啊啊啊啊  on 2024/1/25.
//

#import "BandItemCell.h"

@interface BandItemCell()
@property (weak, nonatomic) IBOutlet UILabel *lb_name;
@property (weak, nonatomic) IBOutlet UISwitch *sw_select;

@end

@implementation BandItemCell

- (void)awakeFromNib {
    [super awakeFromNib];
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

- (void)setModel:(BandItemModel *)model{
    _model = model;
    self.lb_name.text =  model.name;
    [self.sw_select setOn:model.value];
}
- (IBAction)swclick:(UISwitch *)sender {
    self.model.value = sender.isOn ? 1:0;
}

@end
